package com.qimo.zzy.dao;

import com.qimo.zzy.entity.AddressEntity;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface AddressDao {
    /**
     * address表的数据接口层
     */
    //新增地址方法
    int addAddress(int uid, String receiver, String province, String city, String county,String address, String areaCode, String cellPhone, String fixedPhone, String postCode, String tag, int isDefault);

    //修改地址
    int chanceAddress(int addressId, String receiver, String province, String city, String county,String address, String areaCode, String cellPhone, String fixedPhone, String postCode, String tag, int isDefault);

    //删除地址
    int delAddress(int addressId);

    //查询所有地址
    List<AddressEntity> getAddressList(int uid);

    //设为默认
    //int changeIsDefault(int addressId, int isDefault);
}